package com.ruoyi.system.dto;

import com.baomidou.mybatisplus.annotation.TableField;
import com.ruoyi.common.core.page.PageDomainPlus;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;

import javax.validation.constraints.NotNull;

@Data
@ApiModel(description = "微信用户信息")
public class WeChatUserDTO extends PageDomainPlus {


    /**
     * 系统内部唯一用户ID
     */
    @ApiModelProperty(value = "系统内部唯一用户ID", required = true)
    @NotNull(message = "用户ID不能为空", groups = {Add.class, Edit.class})
    private Long userId;

    /**
     * 微信用户在当前应用的唯一标识
     */
    @ApiModelProperty(value = "微信用户在当前应用的唯一标识", required = true)
    @NotNull(message = "openid不能为空", groups = {Add.class, Edit.class})
    private String openid;

    /**
     * 微信开放平台下的唯一标识（跨应用）
     */
    @TableField(value = "unionid")
    @ApiModelProperty(value = "微信开放平台下的唯一标识（跨应用）")
    @NotNull(message = "unionid不能为空", groups = {Edit.class})
    private String unionid;

    public interface Add {
    }

    public interface Edit {
    }
}
